using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._ImageAnalystTools._MultidimensionalAnalysis
{
    /// <summary>
    /// <para>Summarize Categorical Raster</para>
    /// <para>Generates a table containing the pixel count for each class, in each slice of an input categorical raster.</para>
    /// <para>生成一个表，其中包含输入分类栅格的每个切片中每个类的像素计数。</para>
    /// </summary>    
    [DisplayName("Summarize Categorical Raster")]
    public class SummarizeCategoricalRaster : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public SummarizeCategoricalRaster()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_raster">
        /// <para>Input Categorical Raster</para>
        /// <para>The input multidimensional, categorical raster.</para>
        /// <para>输入多维分类栅格。</para>
        /// </param>
        /// <param name="_out_table">
        /// <para>Output Summary Table</para>
        /// <para>The output summary table. Geodatabase, database, text, Microsoft Excel, and comma-separated value (CSV) tables are supported.</para>
        /// <para>输出汇总表。支持地理数据库、数据库、文本、Microsoft Excel 和逗号分隔值 （CSV） 表。</para>
        /// </param>
        public SummarizeCategoricalRaster(object _in_raster, object _out_table)
        {
            this._in_raster = _in_raster;
            this._out_table = _out_table;
        }
        public override string ToolboxName => "Image Analyst Tools";

        public override string ToolName => "Summarize Categorical Raster";

        public override string CallName => "ia.SummarizeCategoricalRaster";

        public override List<string> AcceptEnvironments => ["extent"];

        public override object[] ParameterInfo => [_in_raster, _out_table, _dimension, _aoi, _aoi_id_field];

        /// <summary>
        /// <para>Input Categorical Raster</para>
        /// <para>The input multidimensional, categorical raster.</para>
        /// <para>输入多维分类栅格。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Categorical Raster")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_raster { get; set; }


        /// <summary>
        /// <para>Output Summary Table</para>
        /// <para>The output summary table. Geodatabase, database, text, Microsoft Excel, and comma-separated value (CSV) tables are supported.</para>
        /// <para>输出汇总表。支持地理数据库、数据库、文本、Microsoft Excel 和逗号分隔值 （CSV） 表。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Summary Table")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_table { get; set; }


        /// <summary>
        /// <para>Dimension</para>
        /// <para>The input dimension to use for the summary. If there is more than one dimension and no value is specified, all slices will be summarized using all combinations of dimension values.</para>
        /// <para>用于摘要的输入维度。如果存在多个维度且未指定值，则将使用维度值的所有组合汇总所有剖面。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Dimension")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _dimension { get; set; } = null;


        /// <summary>
        /// <para>Area Of Interest</para>
        /// <para>The polygon feature layer containing the area or areas of interest to use when calculating the pixel count per category. If no area of interest is specified, the entire raster dataset will be included in the analysis.</para>
        /// <para>面要素图层，其中包含在计算每个类别的像素数时要使用的一个或多个感兴趣区域。如果未指定感兴趣区域，则整个栅格数据集将包含在分析中。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Area Of Interest")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _aoi { get; set; } = null;


        /// <summary>
        /// <para>Area Of Interest ID Field</para>
        /// <para>The field in the polygon feature layer that defines each area of interest. Text and integer fields are supported.</para>
        /// <para>面要素图层中用于定义每个感兴趣区域的字段。支持文本和整数字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Area Of Interest ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _aoi_id_field { get; set; } = null;


        public SummarizeCategoricalRaster SetEnv(object extent = null)
        {
            base.SetEnv(extent: extent);
            return this;
        }

    }

}